package com.ruoyi.project.system.mapper;

import java.util.List;

import com.ruoyi.project.system.domain.SysCity;
import org.apache.ibatis.annotations.Param;

/**
 * 城市Mapper接口
 *
 * @author jjp
 * @date 2020-04-09
 */
public interface SysCityMapper {
    /**
     * 查询城市
     *
     * @param cityId 城市ID
     * @return 城市
     */
    public SysCity selectSysCityById(Long cityId);

    /**
     * 查询城市列表
     *
     * @param sysCity 城市
     * @return 城市集合
     */
    public List<SysCity> selectSysCityList(SysCity sysCity);

    /**
     * 查询城市列表
     *
     * @param sysCity 城市
     * @return 城市集合
     */
    public List<SysCity> getByCityName(SysCity sysCity);

    /**
     * 新增城市
     *
     * @param sysCity 城市
     * @return 结果
     */
    public int insertSysCity(SysCity sysCity);

    // 新增省/市
    public int insetCityParentId(SysCity sysCity);

    /**
     * 修改城市
     *
     * @param sysCity 城市
     * @return 结果
     */
    public int updateSysCity(SysCity sysCity);

    /**
     * 删除城市
     *
     * @param cityId 城市ID
     * @return 结果
     */
    public int deleteSysCityById(Long cityId);

    /**
     * 批量删除城市
     *
     * @param cityIds 需要删除的数据ID
     * @return 结果
     */
    public int deleteSysCityByIds(Long[] cityIds);


    /**
     * 显示城市服务
     *
     * @param cityId 城市id
     * @return 结果
     */
    public List<SysCity> QueryCityService(Long cityId);

    public List<SysCity> selectSysParentCityId(Long level);

    public List<SysCity> queryParentName();

    public List<SysCity> queryChirdrenName(SysCity sysCity);

    public List<SysCity> queryByCityName(SysCity sysCity);

}
